﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using FluentNHibernate.Mapping;

namespace RM.Entities.Data
{
    public class LogMap : ClassMap<OperationLog>
    {
        public LogMap()
        {
            Id(x => x.Id).Not.Nullable();

            Map(x => x.Entity).Length(50);
            Map(x => x.Data).Length(100);
            Map(x => x.Message).Length(10000);

            Map(x => x.CreatedDate).Not.Nullable();
            Map(x => x.ModifiedDate).Not.Nullable();
            References(x => x.CreatedBy);
            References(x => x.ModifiedBy);

        }
    }
}
